<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    {include file='Public:head_in' /}
    <link rel="stylesheet" type="text/css" href="__ADMIN__/plugins/check-tree/checktree.css" />
    <script type="text/javascript" src="__ADMIN__/plugins/check-tree/tree.js"></script>
    <script type="text/javascript" src="__ADMIN__/js/plugins/summernote/summernote.js"></script>
</head>
<body>
<div class="panel panel-default">
    <form id="edit_form" action="{:url('admin/Posts/edit_think_posts')}" method="post" class="form-horizontal">
        <div class="panel-body">
            <div class="row">
                <input type="hidden" name="id" value="{$id}">
                <div class="col-xs-11">
                    <div class="form-group">
                        <label class="col-xs-2 control-label">缩略图</label>
                        <div class="col-xs-3">
                            <div class="gallery">
                                <a class="gallery-item"  href="javascript:void('')" title="Space picture 2" data-gallery>
                                    <div class="image" >
                                        <input name="smeta[thumb]" value="{:getAttr($smeta,'thumb')}" hidden type="text" id="inp">
                                        <img src="{:is_img(getAttr($smeta,'thumb'))}" alt="Space picture 2"/>
                                        <ul class="gallery-item-controls">
                                            <li onclick="upload_single('inp','posts')"><i class="fa fa-cloud-upload"></i></li>
                                            <li onclick="del_pic('inp')"><i class="fa fa-times"></i></li>
                                        </ul>
                                    </div>
                                </a>
                            </div>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-xs-2 control-label">上级</label>
                        <div class="col-xs-10">
                            <select multiple name="smeta[term_relation][]" class="form-control select">
                                {volist name='termsList' id='v'}
                                <option {:post_term($id,$v.term_id)} value="{$v.term_id}">{$v.lefthtml}{$v.name}</option>
                                {/volist}
                            </select>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-xs-2 control-label">文章标题</label>
                        <div class="col-xs-10">
                            <div class="input-group">
                                <span class="input-group-addon"><span class="fa fa-pencil"></span></span>
                                <input type="text" value="{$post_title}" name="post_title" class="form-control"/>
                            </div>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-xs-2 control-label">文章摘要</label>
                        <div class="col-xs-10 col-xs-12">
                            <textarea class="form-control" name="post_excerpt" rows="5">{$post_excerpt}</textarea>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-xs-2 control-label"></label>
                        <div class="col-xs-10 col-xs-12">
                            <textarea name="post_content" class="summernote">{$post_content}</textarea>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-xs-2  control-label">是否通过</label>
                        <div class="col-xs-10">
                            <label class="switch">
                                <input type="checkbox" name="post_status" {:is_checked($post_status)} value="1"/>
                                <span class="help-block"></span>
                            </label>
                            <span class="help-block">默认正常</span>
                        </div>
                    </div>
                </div>
            </div>
        </div>
        <div class="panel-footer">
            <button class="btn btn-info pull-right">保存修改<span class="fa fa-floppy-o fa-right"></span></button>
        </div>
    </form>
</div>
</body>
</html>